import http from '@/utils/http2.js'

//查询菜单
export function queryMenu(id) {
  return http.get("/api/menu/query",{id})
}

//查询上级菜单树
export function queryTree() {
  return http.get("/api/menu/tree",{})
}

//保存菜单
export function saveMenu(data) {
  return http.post("/api/menu/save",data)
}

//修改菜单
export function updateMenu(data) {
  return http.put("/api/menu/update", data)
}

//删除菜单
export function deleteMenu(id) {
  return http.delete("/api/menu/delete",{id})
}

//查询菜单树
export function menuTree() {
  return http.get("/api/menu/menuTree",{})
}